<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>注册</title>
</head>
<script type="text/javascript" src="scripts/jquery-1.9.1.min.js"></script>
<script type="text/javascript">
	$(function(){
		$("#findList").click(function(){
			var url = "user/queryList.mvc";
			var args = {};
			$.GET(url, args, function(data){
				for(var i = 0; i < data.length; i++){
					//var instrumentNum = data[i].instrumentNum;
					var unitName = data[i].unitName;
					
					alert(unitName);
				}
			});
			return false;
		});
	})
	
	$(function(){
		$("#findList2").click(function(){
			var url = "user/findunit";
			var args = {};
			$.post(url, args, function(data){
				for(var i = 0; i < data.length; i++){
					var instrumentNum = data[i].instrumentNum;
					var instrumentName = data[i].instrumentName;
					
					alert(instrumentNum + ": " + instrumentName);
				}
			});
			return false;
		});
	})
	
$(function(){
		$("#del").click(function(){
    var unit = {};
    outId[0] = 2;
    outId[1] = 3 ;

    $.ajax({
        url: 'delManyIns',
        method: 'post',
        data: outId, // 以json字符串方式传递
        success: function(data) {
            console.log("success...");
        },
        error: function(data) {
            console.log("error...");
        }
    });
});
});
</script>
<body>
  <a href="queryList" id="findList">Test Json1</a>
  <a href="unit/findunit" id="findList2">Test Json2</a>
  <a href="user/delInstrument/0">Test del</a>
  <a href="delUser/3">Test delUser</a>
  <a href="QRCode?content=123456">Test QRCode</a>
  <a href="createExcel">Test Excel</a>
  <a href="user/saveUnit" id="loginbtn">test addUnit</a>
  <a href="upUser">Test update</a>
  <a href="finalRepair?id=1&status=2">test RF</a>
  <a href="findByMainId?mainId=1">test ENC</a>
  <a href="addBorrow?mainId=1&useReason=5555">test borrow</a>
  <a href="answerBorrow?id=1&status=0">Test answerBorrow</a>
  <a href="delManyIns?outId=45">Test manyIns</a>
  <a href="manyTodead?deadId=67">Test update</a>
  <a href="findManyByUnit">Test findByUnit</a>
  <a href="manyAllocationLand?ids=23&landId=3">test msd</a>
</body>
</html> 